<?php
/* Smarty version 3.1.30, created on 2017-11-05 03:35:49
  from "C:\ComsenzEXP\wwwroot\Moodblog\admin\html\link.html" */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '3.1.30',
  'unifunc' => 'content_59fe8715a620a6_61339266',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    '4fa6e4104c218320d6f28dbef9e993a55ddb78a8' => 
    array (
      0 => 'C:\\ComsenzEXP\\wwwroot\\Moodblog\\admin\\html\\link.html',
      1 => 1509852948,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
  ),
),false)) {
function content_59fe8715a620a6_61339266 (Smarty_Internal_Template $_smarty_tpl) {
?>
<head>
	<link rel="stylesheet" type="text/css" href="./html/common.css" />
</head>
<div class="content">
	<div class = "setTitle">
		友链管理 
		<div class="smallinput">
			<form action="trans.php?action=addlink" method="POST" enctype="multipart/form-data">
				<input style="width:100px;" name="index" type="text" placeholder="友链序号"/> 
				<input style="width:100px;" name="name" type="text" placeholder="友链名称"/> 
				<input style="width:100px;" name="url" type="text" placeholder="友链地址"/> 
				<input name="headpic" type="file"/> 
				<input style="width:100px;" name="introduce" type="text" placeholder="友链介绍"/> 
				<input style="width:100px;" name="color" type="text" placeholder="友链颜色"/> 
				<input style="width:100px;" type="submit" value="添加友链"/>
			</form>
		</div>
	</div>
	<form action="trans.php?action=updatelink" method="POST">
		<table class="setTable">
			<tbody>
				<tr>
					<th>顺序</th>
					<th>名称</th>
					<th>地址</th>
					<th>头像</th>
					<th>介绍</th>
					<th>颜色</th>
					<th>管理</th>
				</tr>
				
					<?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['link']->value, 'value');
if ($_from !== null) {
foreach ($_from as $_smarty_tpl->tpl_vars['value']->value) {
?>
					<tr>
						<td style="width:4%;">
							<input name="id[]" type="hidden" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['id'];?>
">
							<input style="width:100%;" name="index[]" type="text" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['index'];?>
">
						</td>
						<td style="width:8%;"><input style="width:100%;" name="name[]" type="text" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['name'];?>
"></td>
						<td><input style="width:100%;" name="url[]" type="text" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['url'];?>
"></td>
						<td style="width:10%;"><input style="width:100%;" name="headpic[]" type="text" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['headpic'];?>
"></td>
						<td><input style="width:100%;" name="introduce[]" type="text" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['introduce'];?>
"></td>
						<td style="width:7%;" ><input style="width:100%;" name="color[]" type="text" value="<?php echo $_smarty_tpl->tpl_vars['value']->value['color'];?>
"></td>
						<td><a href="trans.php?action=deletelink&id=<?php echo $_smarty_tpl->tpl_vars['value']->value['id'];?>
">删除</a></td>
					</tr>
					<?php
}
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl);
?>

			</tbody>
		</table>
		<div class="adminSub">
			<input type="submit" value="提交"/>
		</div>
	</form>
</div>
<?php }
}
